iT邦幫忙

第 11 屆 iThome 鐵人賽

DAY 6
0
自我挑戰組

30天學 LAMP 安裝系列 第 6

Day06 以 Minimal 進行 CentOS 7 文字模式的基本安裝

  • 分享至 

  • xImage
  •  

前言

  • 因為在預先測試的過程中,發覺在 CentOS 7 圖形模式下安裝軟體、設定服務等全都使用圖形程式的方式來做操作有困難,經常還是得開個 Terminal 終端機,以下指令的方式進行操作。既然這樣,那我們就提前開始以 CentOS 7 Minimal 的方式做操作。
  • 使用 ISO 檔為 CentOS-7-x86_64-Minimal-1810.iso
  • 安裝過程中,IP 先使用 DHCP
  • root 密碼為 password
  • 參考網址:http://partnerweb.vmware.com/GOSIG/CentOS_7.html

安裝步驟

  1. 新建一個虛擬機器,步驟如同 Day03 的過程,虛擬機器名稱取名為 CentOS 7 CLI,最後一個步驟掛載 ISO 檔換成 CentOS-7-x86_64-Minimal-1810.iso。

  2. 安裝步驟大部分與 Day04 相同,不同的部分如以下說明:

    1. SOFTWARE SELECTION

      就只有 Minimal Install 可以選

      https://ithelp.ithome.com.tw/upload/images/20190909/20119707GYeTepej9z.png

    2. NETWORK & HOSTNAME

      透過 DHCP 這次所得到的 IP 為 192.168.250.102,其餘設定相同。Host name 主機名稱這次設定為 centos7-cli.lab.example.com。

      https://ithelp.ithome.com.tw/upload/images/20190909/20119707JB7YdEDxRD.png

    3. 全部設定完,再檢查一遍,按下 Begin Installation 開始進行安裝

      https://ithelp.ithome.com.tw/upload/images/20190909/20119707VVKy6TWNtm.png

    4. 重開機後,就只剩下指令列介面可以使用了,還是可以用 root 帳號登入。

       CentOS Linux 7 (Core)
       Kernel 3.10.0-957.el7.x86_64 on an x86_64
      
       centos7-cli login: root
       Password:
       [root@centos7-c1i ~]#
      
    5. 登入後,會發現我最喜歡 Linux 的「指令自動補全」的功能卡卡,能自動補的不多,此時便要安裝 bash-completion 套件。

      [root@centos7-cli ~]# yum install bash-completion -y
      Loaded plugins: fastestmirror
      Loading mirror speeds from cached hostfile
       * base: ftp.yzu.edu.tw
       * extras: ftp.yzu.edu.tw
       * updates: ftp.yzu.edu.tw
      Resolving Dependencies
      --> Running transaction check
      ---> Package bash-completion.noarch 1:2.1-6.el7 will be installed
      --> Finished Dependency Resolution
      
      Dependencies Resolved
      
      ==========================================================================================================================
       Package                           Arch                     Version                          Repository              Size
      ==========================================================================================================================
      Installing:
       bash-completion                   noarch                   1:2.1-6.el7                      base                    85 k
      
      Transaction Summary
      ==========================================================================================================================
      Install  1 Package
      
      Total download size: 85 k
      Installed size: 259 k
      Downloading packages:
      warning: /var/cache/yum/x86_64/7/base/packages/bash-completion-2.1-6.el7.noarch.rpm: Header V3 RSA/SHA256 Signature, key I                                                                                                                   D f4a80eb5: NOKEY
      Public key for bash-completion-2.1-6.el7.noarch.rpm is not installed
      bash-completion-2.1-6.el7.noarch.rpm                                                               |  85 kB  00:00:00
      Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
      Importing GPG key 0xF4A80EB5:
       Userid     : "CentOS-7 Key (CentOS 7 Official Signing Key) <security@centos.org>"
       Fingerprint: 6341 ab27 53d7 8a78 a7c2 7bb1 24c6 a8a7 f4a8 0eb5
       Package    : centos-release-7-6.1810.2.el7.centos.x86_64 (@anaconda)
       From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
      Running transaction check
      Running transaction test
      Transaction test succeeded
      Running transaction
        Installing : 1:bash-completion-2.1-6.el7.noarch                                                                     1/1
        Verifying  : 1:bash-completion-2.1-6.el7.noarch                                                                     1/1
      
      Installed:
        bash-completion.noarch 1:2.1-6.el7
      
      Complete!
      [root@centos7-cli ~]# 
      
    6. (選擇性安裝)既然此虛擬機是跑在 VMware Workstatiion 上,那也順便安裝 VMware Tools 吧!

      [root@centos7-cli ~]# yum install open-vm-tools -y
      Loaded plugins: fastestmirror
      Loading mirror speeds from cached hostfile
       * base: ftp.yzu.edu.tw
       * extras: ftp.yzu.edu.tw
       * updates: ftp.yzu.edu.tw
      Resolving Dependencies
      --> Running transaction check
      ---> Package open-vm-tools.x86_64 0:10.2.5-3.el7 will be installed
      --> Processing Dependency: xmlsec1-openssl for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: pciutils for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libfuse.so.2(FUSE_2.6)(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libfuse.so.2(FUSE_2.5)(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: fuse for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libxslt.so.1()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libxmlsec1.so.1()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libmspack.so.0()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libltdl.so.7()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libicuuc.so.50()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libicui18n.so.50()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libicudata.so.50()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libfuse.so.2()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Processing Dependency: libdnet.so.1()(64bit) for package: open-vm-tools-10.2.5-3.el7.x86_64
      --> Running transaction check
      ---> Package fuse.x86_64 0:2.9.2-11.el7 will be installed
      ---> Package fuse-libs.x86_64 0:2.9.2-11.el7 will be installed
      ---> Package libdnet.x86_64 0:1.12-13.1.el7 will be installed
      ---> Package libicu.x86_64 0:50.1.2-17.el7 will be installed
      ---> Package libmspack.x86_64 0:0.5-0.6.alpha.el7 will be installed
      ---> Package libtool-ltdl.x86_64 0:2.4.2-22.el7_3 will be installed
      ---> Package libxslt.x86_64 0:1.1.28-5.el7 will be installed
      ---> Package pciutils.x86_64 0:3.5.1-3.el7 will be installed
      ---> Package xmlsec1.x86_64 0:1.2.20-7.el7_4 will be installed
      ---> Package xmlsec1-openssl.x86_64 0:1.2.20-7.el7_4 will be installed
      --> Finished Dependency Resolution
      
      Dependencies Resolved
      
      ==========================================================================================================================
       Package                          Arch                    Version                             Repository             Size
      ==========================================================================================================================
      Installing:
       open-vm-tools                    x86_64                  10.2.5-3.el7                        base                  669 k
      Installing for dependencies:
       fuse                             x86_64                  2.9.2-11.el7                        base                   86 k
       fuse-libs                        x86_64                  2.9.2-11.el7                        base                   93 k
       libdnet                          x86_64                  1.12-13.1.el7                       base                   31 k
       libicu                           x86_64                  50.1.2-17.el7                       base                  6.9 M
       libmspack                        x86_64                  0.5-0.6.alpha.el7                   base                   64 k
       libtool-ltdl                     x86_64                  2.4.2-22.el7_3                      base                   49 k
       libxslt                          x86_64                  1.1.28-5.el7                        base                  242 k
       pciutils                         x86_64                  3.5.1-3.el7                         base                   93 k
       xmlsec1                          x86_64                  1.2.20-7.el7_4                      base                  177 k
       xmlsec1-openssl                  x86_64                  1.2.20-7.el7_4                      base                   76 k
      
      Transaction Summary
      ==========================================================================================================================
      Install  1 Package (+10 Dependent packages)
      
      Total download size: 8.4 M
      Installed size: 28 M
      Downloading packages:
      (1/11): fuse-libs-2.9.2-11.el7.x86_64.rpm                                                          |  93 kB  00:00:00
      (2/11): fuse-2.9.2-11.el7.x86_64.rpm                                                               |  86 kB  00:00:00
      (3/11): libdnet-1.12-13.1.el7.x86_64.rpm                                                           |  31 kB  00:00:00
      (4/11): libmspack-0.5-0.6.alpha.el7.x86_64.rpm                                                     |  64 kB  00:00:00
      (5/11): libtool-ltdl-2.4.2-22.el7_3.x86_64.rpm                                                     |  49 kB  00:00:00
      (6/11): libxslt-1.1.28-5.el7.x86_64.rpm                                                            | 242 kB  00:00:00
      (7/11): open-vm-tools-10.2.5-3.el7.x86_64.rpm                                                      | 669 kB  00:00:00
      (8/11): pciutils-3.5.1-3.el7.x86_64.rpm                                                            |  93 kB  00:00:00
      (9/11): libicu-50.1.2-17.el7.x86_64.rpm                                                            | 6.9 MB  00:00:01
      (10/11): xmlsec1-1.2.20-7.el7_4.x86_64.rpm                                                         | 177 kB  00:00:00
      (11/11): xmlsec1-openssl-1.2.20-7.el7_4.x86_64.rpm                                                 |  76 kB  00:00:00
      --------------------------------------------------------------------------------------------------------------------------
      Total                                                                                     4.0 MB/s | 8.4 MB  00:00:02
      Running transaction check
      Running transaction test
      Transaction test succeeded
      Running transaction
        Installing : libtool-ltdl-2.4.2-22.el7_3.x86_64                                                                    1/11
        Installing : libxslt-1.1.28-5.el7.x86_64                                                                           2/11
        Installing : xmlsec1-1.2.20-7.el7_4.x86_64                                                                         3/11
        Installing : xmlsec1-openssl-1.2.20-7.el7_4.x86_64                                                                 4/11
        Installing : pciutils-3.5.1-3.el7.x86_64                                                                           5/11
        Installing : libdnet-1.12-13.1.el7.x86_64                                                                          6/11
        Installing : libmspack-0.5-0.6.alpha.el7.x86_64                                                                    7/11
        Installing : libicu-50.1.2-17.el7.x86_64                                                                           8/11
        Installing : fuse-2.9.2-11.el7.x86_64                                                                              9/11
        Installing : fuse-libs-2.9.2-11.el7.x86_64                                                                        10/11
        Installing : open-vm-tools-10.2.5-3.el7.x86_64                                                                    11/11
        Verifying  : fuse-libs-2.9.2-11.el7.x86_64                                                                         1/11
        Verifying  : fuse-2.9.2-11.el7.x86_64                                                                              2/11
        Verifying  : xmlsec1-openssl-1.2.20-7.el7_4.x86_64                                                                 3/11
        Verifying  : libicu-50.1.2-17.el7.x86_64                                                                           4/11
        Verifying  : libxslt-1.1.28-5.el7.x86_64                                                                           5/11
        Verifying  : xmlsec1-1.2.20-7.el7_4.x86_64                                                                         6/11
        Verifying  : libmspack-0.5-0.6.alpha.el7.x86_64                                                                    7/11
        Verifying  : libdnet-1.12-13.1.el7.x86_64                                                                          8/11
        Verifying  : libtool-ltdl-2.4.2-22.el7_3.x86_64                                                                    9/11
        Verifying  : open-vm-tools-10.2.5-3.el7.x86_64                                                                    10/11
        Verifying  : pciutils-3.5.1-3.el7.x86_64                                                                          11/11
      
      Installed:
        open-vm-tools.x86_64 0:10.2.5-3.el7
      
      Dependency Installed:
        fuse.x86_64 0:2.9.2-11.el7                fuse-libs.x86_64 0:2.9.2-11.el7        libdnet.x86_64 0:1.12-13.1.el7
        libicu.x86_64 0:50.1.2-17.el7             libmspack.x86_64 0:0.5-0.6.alpha.el7   libtool-ltdl.x86_64 0:2.4.2-22.el7_3
        libxslt.x86_64 0:1.1.28-5.el7             pciutils.x86_64 0:3.5.1-3.el7          xmlsec1.x86_64 0:1.2.20-7.el7_4
        xmlsec1-openssl.x86_64 0:1.2.20-7.el7_4
      
      Complete!
      [root@centos7-cli ~]#
      

上一篇
Day05 CentOS 7 圖形模式下更改為固定 IP
下一篇
Day07 CentOS 7 文字模式下更改為固定 IP
系列文
30天學 LAMP 安裝33
圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言